package aip2011.controller.localita;



import org.slim3.controller.Controller;
import org.slim3.controller.Navigation;
import org.slim3.controller.upload.FileItem;
import org.slim3.util.RequestMap;

import aip2011.service.LocalitaService;


public class InsertController extends Controller {

private LocalitaService service=new LocalitaService();
    
    @Override
    public Navigation run() throws Exception {
        FileItem immagine = requestScope("immagine");
        service.insert(new RequestMap(request), immagine);
        return redirect("/localita");
    }
}
